package com.yjt.gcss.gddw.common.dao;

import java.util.ArrayList;
import java.util.Collection;

import org.hibernate.criterion.Order;
import org.springframework.stereotype.Service;

import com.yjt.common.hibernate.base.AbstractDaoImpl;
import com.yjt.common.hibernate.base.DaoException;
import com.yjt.gcss.gddw.common.bean.domain.BtOrgBankidMapping;
import com.yjt.gcss.gddw.common.bean.domain.BtOrgBankidMappingId;

@Service(BtOrgBankIDMappingDao.BEAN_PACKAGE_NAME)
public class BtOrgBankIDMappingDao extends AbstractDaoImpl{
	public static final String BEAN_PACKAGE_NAME = "com.yjt.gcss.gddw.common.dao.BtOrgBankIDMappingDao";
	public BtOrgBankIDMappingDao() {
		
	}
	
	public BtOrgBankidMapping getBeanById(BtOrgBankidMappingId id) throws DaoException {
		return ( BtOrgBankidMapping) getBeanById(BtOrgBankidMapping.BEAN_PACKAGE_NAME, id, false);
	}
	
	public BtOrgBankidMapping getBeanByIdForUpdate(BtOrgBankidMappingId id) throws DaoException {
		return (BtOrgBankidMapping) getBeanById(BtOrgBankidMapping.BEAN_PACKAGE_NAME, id, true);
	}

	@SuppressWarnings("rawtypes")
	public Collection getAll() throws DaoException {
		return getAll(BtOrgBankidMapping.BEAN_PACKAGE_NAME);
	}

	@SuppressWarnings("rawtypes")
	public BtOrgBankidMapping getBeanByParams(String hqlName,ArrayList paraList) throws DaoException{
		return (BtOrgBankidMapping) getProtoBeanByParams(hqlName,paraList);
	}
	
	public BtOrgBankidMapping setOrder(Order order){
		return (BtOrgBankidMapping)super.addOrder(order);
	}
}
